package com.adopapa.nezhacloud.authc.domain;

import java.util.List;

import com.adopapa.nezhacloud.ddd.codegen.CodeGen;
import com.adopapa.nezhacloud.ddd.domain.BaseUuidEntity;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Lob;
import jakarta.persistence.Table;
import jakarta.persistence.Transient;

@Entity
@Table(name = "AUTHC_ROLE")
public class RoleInfo extends BaseUuidEntity {

	private static final long serialVersionUID = -8342393890099710271L;

	@CodeGen(query = "%", form = true, required = true, label = "角色名称")
	@Column(name = "USER_NAME")
	private String roleName;
	@CodeGen(form = true, label = "备注")
	@Lob
	@Column(name = "REMARK")
	private String remark;

	@Transient
	private List<ResourcePerm> permissions;

	public String getRoleName() {
		return roleName;
	}

	public void setRoleName(String roleName) {
		this.roleName = roleName;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public List<ResourcePerm> getPermissions() {
		return permissions;
	}

	public void setPermissions(List<ResourcePerm> permissions) {
		this.permissions = permissions;
	}

}
